﻿@{
    ViewBag.Title = Local("NewForumView.PageTitle");
    ViewBag.ActionMenu = "forumsview";
}

@model Forum

@using (Html.BeginForm())
{
<div class="box">
    <label>@GLocal("Forum.ForumName")</label>
    <div class="right">
        @Html.TextBoxFor(model => model.ForumName)
    </div>
</div>
    
<div class="box">
    <label>@GLocal("Forum.Key")</label>
    <div class="right">
        @Html.TextBoxFor(model => model.Key)
        <div class="summary">@GLocal("Forum.Key.Summary")</div>
    </div>
</div>
    
<div class="box">
    <label>@GLocal("Forum.IsVisiable")</label>
    <div class="right">
        @Html.CheckBoxFor(model => model.IsVisiable)
    </div>
</div>
    
<div class="box">
    <label>@GLocal("Forum.ParentID")</label>
    <div class="right">
        @Html.DropDownListForumFor(model => model.ParentID)
    </div>
</div>
    
<div class="box">
    <label>@GLocal("Forum.LogoUrl")</label>
    <div class="right winput">
        @Html.TextBoxFor(model => model.LogoUrl, new { @readonly = "readonly" })
        <div style="margin-top:10px;">
            <img src="@Model.LogoUrl" alt="@GLocal("Forum.ClickSelectedIcon")" title="@GLocal("Forum.ClickSelectedIcon")" id="logo" onclick="return openModal('@Mozlite.Web.UI.Areas.UCenter.UCenterUrls.DialogDiskView?type=8', 650);" style="width:@(DiscussApplication.Current.Configuration.ForumIconWidth)px; height:@(DiscussApplication.Current.Configuration.ForumIconHeight)px;" />
        </div>
    </div>
</div>
    
<div class="box">
    <label>@GLocal("Forum.Summary")</label>
    @Html.TextAreaFor(model => model.Summary)
</div>
    
<div class="box">
    <label>@GLocal("Forum.SchemaID")</label>
    <div class="right">
        @Html.ForumPermissionSchemaDropDownListFor(model => model.SchemaID)
    </div>
</div>
    
<div class="box">
    <button> @GLocal("Forum.Save") </button>
</div>
<script type="text/javascript">
    function callback(id) {
        var url = '@GetFileBrowserUrl()' + id;
        $('#logo').attr('src', url);
        $('#LogoUrl').val(url);
    }
</script>
}

